﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Milestone.Model.Parties;
using Newtonsoft.Json;

namespace Milestone.Model.Projects
{
	public class Project
	{
		[JsonConstructor]
		private Project()
		{

		}

		public String Id { get; private set; }
		public String Name { get; private set; }
		public DenormalizedParty Owner { get; private set; }
		public Decimal DefaultDailyRate { get; private set; }

		public static Project CreateNew( string projectName, DenormalizedParty owner, Decimal defaultDailyRate )
		{
			var company = new Project()
			{
				Name = projectName,
				Owner = owner,
				DefaultDailyRate = defaultDailyRate
			};

			return company;
		}
	}
}
